home *** CD-ROM | disk | FTP | other *** search
/ MacHack 2000 / MacHack 2000.toast / pc / The Hacks / Easy as pi dcmd ƒ / useful.p < prev   
Encoding:
Text File  |  2000-06-23  |  2.4 KB  |  62 lines

  1. {    useful dcmd (not!) }
  2. {    Created at MacHack 2000 by Philippe Casgrain }
  3. {    philippe@casgrain.com }
  4.  
  5. {    This file is best viewed in a monospace font. }
  6.  
  7. {    This dcmd compiles well under MPW 3.2 using the old style interfaces. I have not }
  8. {    attempted to make it compile under 3.3 and universal interfaces, mostly because }
  9. {    I use the Pascal compiler which is 68k only so the new routine names don't  }
  10. {    really matter. }
  11.  
  12. unit pi;
  13.  
  14. {$R-}
  15. { debug labels on. }
  16. {$D+}
  17.  
  18. interface
  19.  
  20.     uses
  21.         MemTypes, Packages, Scrap, {}
  22.         dcmd; { Macsbug interface routines. }
  23.  
  24.     { Public declaration for dcmdGlue. Must be in every dcmd. The name cannot be changed. }
  25.     procedure CommandEntry (paramPtr: dcmdBlockPtr);
  26.  
  27. implementation
  28.  
  29. {-------------------------------------------------------------------------------------------}
  30.  
  31.  
  32. { This procedure is the main entry point for the dcmd.  It is the hook by which we get }
  33. {    called by MacsBug to do our thing. It is basically the chance to key off the command }
  34. {    line and do what it requests. }
  35.     procedure CommandEntry (paramPtr: DCmdBlockPtr);
  36.     begin
  37.         case paramPtr^.request of
  38.             dcmdInit: 
  39.                 ; { We have no initalizations to do in this very simple dcmd }
  40.  
  41.             dcmdDoIt, dcmdHelp:  begin 
  42.                 dcmdDrawLine('                                                              ');
  43.                 dcmdDrawLine('                                                              ');
  44.                 dcmdDrawLine('                                                              ');
  45.                 dcmdDrawLine('##   ##   #######   #######   #######   ##   ##   ##       ###');
  46.                 dcmdDrawLine('##   ##   #######   #######   #######   ##   ##   ##       ###');
  47.                 dcmdDrawLine('##   ##   ###       ##        ##        ##   ##   ##       ###');
  48.                 dcmdDrawLine('##   ##   #######   #####     #####     ##   ##   ##       ###');
  49.                 dcmdDrawLine('##   ##   #######   #####     #####     ##   ##   ##        # ');
  50.                 dcmdDrawLine('##   ##       ###   ##        ##        ##   ##   ##          ');
  51.                 dcmdDrawLine('#######   #######   #######   ##        #######   #######  ###');
  52.                 dcmdDrawLine('#######   #######   #######   ##        #######   #######  ###');
  53.                 dcmdDrawLine('                                                              ');
  54.                 dcmdDrawLine('                                                              ');
  55.                 dcmdDrawLine('                                                              ');
  56.             end; { dcmdDoIt, dcmdHelp }
  57.                 
  58.         end; { case paramPtr^.request. }
  59.  
  60.     end; { CommandEntry }
  61.  
  62. end.